home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Magnum One
/
Magnum One (Mid-American Digital) (Disc Manufacturing).iso
/
d18
/
tpdb314.arc
/
ZAP.PAS
< prev
Wrap
Pascal/Delphi Source File
|
1991-01-30
|
871b
|
36 lines
{$A+,B+,D-,E-,F-,I-,L-,N-,O-,R-,S-,V-}
{$M 65520,0,655360}
Program ZapFile;
Uses Crt,TPDB,TPDBScrn,TPDBStr;
Var
Message : String[80];
Zapper : ^DBF;
begin
CursorOff;
If ParamCount = 0 then
begin
Beep;
ClrScr;
Flash(1,1,LightGreen+BlackBG,'ZAP filename.dbf');
CursorOn;
Halt(1);
end;
NEW(Zapper,Init(ParamStr(1)));
If Zapper^.TotalRecs = 0 then
begin
ClrScr;
Beep;
Message := 'Record count in file '+Upper(ParamStr(1))+' is already ZERO.';
Flash(1,1,LightGreen+BlackBG,Message);
CursorOn;
Halt(1);
end;
Zapper^.Zap;
Zapper^.Done;
ClrScr;
FlashC(12,White+BlackBG,'File has been zapped.');
FlashC(13,LightGreen+BlackBG,'Copyright 1989 Brian Corll');
CursorOn;
end.